package AC;
import java.util.InputMismatchException;
import java.util.Scanner;
public class A {
    public static void main(String[] args) {
        String[] a = {"C++", "java", "qianduan"};
        Scanner in = new Scanner(System.in);
        try {
            System.out.print("请输入课程代号：");
            int num = in.nextInt();
            System.out.println(a[num - 1] + " 课程");
        } catch (NullPointerException e) {
            System.err.println("只能输入1-3以内的数字，您输入的已超出范围！");
            e.printStackTrace();
        } catch (InputMismatchException e) {
            System.err.println("请输入数字！");
            e.printStackTrace();
        } catch (Exception e) {
            System.err.println("输入错误！");
            e.printStackTrace();
        }
    }
}
